#ifndef  CONV_H
#define  CONV_H
#include <stdint.h>

//void    PDU_conv_cat_HT_value2UCS2(uint32_t value, char *dest);//转换大棚温湿度值为UCS2格式，并cat至字符串dest
//void    PDU_conv_cat_DP_no2UCS2(uint32_t no, char *dest); //换大棚序号为UCS2格式，并cat至字符串dest

char*   conv_PDU_tel_to_normal_tel(char *src, int len);
uint8_t conv_hex_ch_to_bin(char ch);
char *  conv_PDU_date_to_CCLK_date (char *PDU_string); //把PDU格式的时间转换为AT+CCLK可以识别的时间
void    conv_pdu2asc(const char *src, char *dest, int len);//把pdu格式字符串转换为ascii字符串
void    conv_toupper(char *msg, int len); //所有字符变大写

int     conv_ucs2_to_utf8(const char *ibuf, size_t inbytes,
        char *obuf, size_t *outbytes); //转换UCS2编码为UTF8编码

int conv_pdu_to_utf8(const char *str, int len, char *outbuf, size_t *outbytes);
int conv_pdu_to_bin(const char *string, char *array, size_t *size);

int conv_char_7bit_pdu_unpack(const char *str, int inlen, char *outbin, size_t *outlen); //转换7bit的pdu字符串为8为的二进制

#endif  /*CONV_H*/
